<template>
  <view :style="themeColor">
    <view class="page">
      <view class="flex flex-direction flex-wrap align-stretch benben-position-layout flex dailyExpenditure_flex_0"
        :style="{height:(88+StatusBarRpx)+'rpx',paddingTop:StatusBarRpx+'rpx', }">
        <view class='flex flex-wrap align-center justify-between flex-sub dailyExpenditure_fd0_0'>
          <view class='flex flex-wrap align-center dailyExpenditure_fd0_0_c0' @tap.stop="handleJumpDiy" data-type="back"
            data-url="1">
            <text class='fu-iconfont2  dailyExpenditure_fd0_0_c0_c0'>&#xE794;</text>
          </view>
          <view class='flex flex-wrap align-stretch justify-center'>
            <text class='dailyExpenditure_fd0_0_c1_c0'>今日收支</text>
          </view>
          <view class='flex flex-wrap align-center justify-end dailyExpenditure_fd0_0_c0'>
            <image class='dailyExpenditure_fd0_0_c2_c0' mode="aspectFit" :src='STATIC_URL+"7.png"'></image>
          </view>
        </view>

      </view>
      <view :style="{height: (88+StatusBarRpx)+'rpx'}"></view>
      <!---flex布局flex布局开始-->
      <view class="flex flex-direction flex-wrap align-stretch benben-flex-layout dailyExpenditure_flex_1">
        <view class='flex flex-wrap align-center'>
          <view>
            <benben-flex-tabs class-name='dailyExpenditure_benbenTabsfd1_0_c0' v-model="tabls" ref="benben_tabsfd1_0_c0"
              @change="getListFunc()" select-mark="benben_tabsfd1_0_c0" key="benben_tabsfd1_0_c0"
              :open-title-type='false' :open-sticky='true' :top='0' :is-show-content='false' :scrollspy='false'
              :tabs-info.sync="tabsInfofd1_0_c0">

              <scroll-view @scroll="tabsInfofd1_0_c0.scrollX = $event.detail.scrollLeft" id="benben_tabsfd1_0_c0"
                class="benben-tabs" style="width:750rpx" :scroll-x="true" :scroll-left.sync="tabsInfofd1_0_c0.moveX"
                scroll-with-animation="all .3s ease">
                <view class="benben-tabs-content" id="benben_tabsfd1_0_c0-content">
                  <view id="benben_tabsfd1_0_c0-title" class="benben-tabs-title flex flex align-center justify-around">
                    <view :class="{ 'checkTitlefd1_0_c0': tabls == '1', 'flex flex-wrap align-center': true }"
                      @tap="tabls = '1'" :id="`benben_tabsfd1_0_c0-title-item-${'1'}`">

                      <text>收购</text>

                    </view>
                    <view :class="{ 'checkTitlefd1_0_c0': tabls == '2', 'flex flex-wrap align-center': true }"
                      @tap="tabls = '2'" :id="`benben_tabsfd1_0_c0-title-item-${'2'}`">

                      <text>出售</text>

                    </view>
                  </view>
                  <view :style="{ left: tabsInfofd1_0_c0.lineleft, maxWidth: tabsInfofd1_0_c0.lineWidth ,}"
                    id="benben_tabsfd1_0_c0-line"
                    class="benben-tabs-line flex benben-flex-tabs-line dailyExpenditure_linefd1_0_c0"></view>
                </view>
              </scroll-view>

            </benben-flex-tabs>

          </view>
        </view>
        <view class='flex flex-wrap align-center dailyExpenditure_fd1_1'>
          <view class='flex flex-wrap align-center dailyExpenditure_fd1_1_c0'>
            <text class='dailyExpenditure_fd1_1_c0_c0'>{{ date}}</text>
          </view>
        </view>
      </view>

      <!---flex布局flex布局结束-->
      <!---flex布局flex布局开始-->
      <view class="flex flex-direction flex-wrap align-stretch benben-flex-layout dailyExpenditure_flex_2">
        <view class='flex flex-direction flex-wrap align-stretch dailyExpenditure_fd2_0'
          v-for="(item,index) in dataList" :key="index">
          <view class='flex flex-wrap align-center justify-between'>
            <text class='dailyExpenditure_fd2_0_c0_c0'>{{item.leixing_name}}</text>
            <view class='flex flex-wrap align-center'>
              <text class='dailyExpenditure_fd2_0_c0_c1_c0'>品种:</text>
              <text class='dailyExpenditure_fd2_0_c0_c1_c1'>{{item.pinzhong_name}}</text>
            </view>
          </view>
          <view class='flex flex-wrap align-center'>
            <view class='flex flex-direction flex-wrap align-stretch dailyExpenditure_fd2_0_c1_c0'>
              <view class='flex flex-wrap align-center dailyExpenditure_fd2_0_c1_c0_c0'>
                <text class='dailyExpenditure_fd2_0_c1_c0_c0_c0'>毛重:</text>
                <text class='dailyExpenditure_fd2_0_c1_c0_c0_c1'>{{item.maozhong}}斤</text>
              </view>
              <view class='flex flex-wrap align-center dailyExpenditure_fd2_0_c1_c0_c0'>
                <text class='dailyExpenditure_fd2_0_c1_c0_c0_c0'>皮重:</text>
                <text class='dailyExpenditure_fd2_0_c1_c0_c0_c1'>{{item.pizhong}}斤</text>
              </view>
              <view class='flex flex-wrap align-center dailyExpenditure_fd2_0_c1_c0_c0'>
                <text class='dailyExpenditure_fd2_0_c1_c0_c0_c0'>净重:</text>
                <text class='dailyExpenditure_fd2_0_c1_c0_c0_c1'>{{item.jingzhong}}斤</text>
              </view>
            </view>
            <view class='flex flex-direction flex-wrap align-stretch flex-sub'>
              <view class='flex flex-wrap align-center dailyExpenditure_fd2_0_c1_c0_c0'>
                <text class='dailyExpenditure_fd2_0_c1_c1_c0_c0'>送粮人:</text>
                <text class='dailyExpenditure_fd2_0_c1_c0_c0_c1'>{{item.songliangren}}</text>
              </view>
              <view class='flex flex-wrap align-center dailyExpenditure_fd2_0_c1_c0_c0'>
                <text class='dailyExpenditure_fd2_0_c1_c1_c0_c0'>价格:</text>
                <text class='dailyExpenditure_fd2_0_c1_c0_c0_c1'>{{item.shougoujia}}元/斤</text>
              </view>
              <view class='flex flex-wrap align-center dailyExpenditure_fd2_0_c1_c0_c0'>
                <text class='dailyExpenditure_fd2_0_c1_c1_c0_c0'>金额:</text>
                <text class='dailyExpenditure_fd2_0_c1_c0_c0_c1'>{{item.jine}}元</text>
              </view>
            </view>
          </view>
          <!--      <view class='flex flex-wrap align-center dailyExpenditure_fd2_0_c1_c0_c0'>
            <text class='dailyExpenditure_fd2_0_c2_c0'>备注:</text>
            <text class='dailyExpenditure_fd2_0_c1_c0_c0_c1'>今天的第三车,大概10车,需要慢慢来</text>
          </view>
          <view class='flex flex-wrap align-start dailyExpenditure_fd2_0_c1_c0_c0'>
            <text class='dailyExpenditure_fd2_0_c3_c0'>凭证:</text>
            <view class='flex flex-wrap align-center flex-sub'>
              <view class='flex flex-wrap align-center dailyExpenditure_fd2_0_c3_c1_c0'>
                <image class='dailyExpenditure_fd2_0_c3_c1_c0_c0' mode="aspectFit" :src='STATIC_URL+"4.png"'></image>
              </view>
              <view class='flex flex-wrap align-center dailyExpenditure_fd2_0_c3_c1_c0'>
                <image class='dailyExpenditure_fd2_0_c3_c1_c0_c0' mode="aspectFit" :src='STATIC_URL+"4.png"'></image>
              </view>
            </view>
          </view> -->
          <view class='flex flex-wrap align-center justify-end dailyExpenditure_fd2_0_c4'>
            <button class='dailyExpenditure_fd2_0_c4_c0' @tap.stop="handleJumpDiy" data-type="navigateTo"
              :data-url="`/pages/wode/dailyexpenditureModification/dailyexpenditureModification?aid=${item.aid}`">修改</button>
          </view>
        </view>
        <fu-empty :pagingListLoadedAll="pagingListLoadedAll" :pagingListNoListData="pagingListNoListData"
          :listDataLength="listDataLength" :isLoadInit="isLoadInit"></fu-empty>
      </view>

      <!---flex布局flex布局结束-->


    </view>
  </view>
</template>
<script>
  import pagingList from '@/common/mixin/paging_list.js';
  export default {
    components: {},
    mixins: [pagingList],
    data() {
      return {
        "tabsInfofd1_0_c0": {
          lineleft: '',
          lineWidth: '',
          moveX: 0,
          scrollX: 0,
          PageScrollX: 0
        },
        "tabls": "1",
        "minixPagingListsApi": "",
        "pageingListApiMethod": "",
        "allowOnloadGetList": false,
        dataList: [],
        date: ''
      };
    },
    computed: {
      themeColor() {
        return this.$store.getters.themeColor
      },

    },
    watch: {},
    onLoad(options) {
      var timeStamp = new Date();
      if (options.create_time) {
        this.date = options.create_time
      } else {
        this.date = this.$util.timeFormat(timeStamp, 'yy-mm-dd')
      }
    },
    onUnload() {

    },
    onReady() {

    },
    onShow() {
      this.getListFunc()
    },
    onHide() {

    },
    onResize() {

    },
    onPullDownRefresh() {

    },
    onReachBottom(e) {

    },
    onPageScroll(e) {

    },
    methods: {
      getListFunc() {
        this.minixPagingListsApi = global.apiUrls.post65d6df72637a6;
        this.pageingListApiMethod = 'get';
        this.allowOnloadGetList = false;
        this.pagingListPostDataContent = {
          leixing: this.tabls,
          create_time: this.date
        }
        this.listData = [];
        this.dataList = this.listData;
        // this.date = this.dataList[0].create_time
        this.pagingListToggle();
      },
      pagingListPostData() {
        return this.pagingListPostDataContent
      }
    }
  };
</script>
<style lang="scss" scoped>
  .page {
    width: 100vw;
    overflow-x: hidden;
    min-height: calc(100vh - var(--window-bottom));
    background: rgba(248, 248, 250, 1);
    background-size: 100% auto;
  }

  .dailyExpenditure_flex_0 {
    background: rgba(255, 255, 255, 1);
    width: 750rpx;
    height: 88rpx;
    overflow: hidden;
    z-index: 10;
    top: 0rpx;
    background-size: 100% auto;
  }

  .dailyExpenditure_fd0_0_c2_c0 {
    width: 119rpx;
    height: 55rpx;
    border-radius: 0rpx 0rpx 0rpx 0rpx;
  }

  .dailyExpenditure_fd0_0_c1_c0 {
    font-size: 36rpx;
    font-weight: 700;
    color: #333333;
    line-height: 50rpx;
  }

  .dailyExpenditure_fd0_0_c0_c0 {
    font-size: 36rpx;
    color: #333;
  }

  .dailyExpenditure_fd0_0_c0 {
    width: 120rpx;
  }

  .dailyExpenditure_fd0_0 {
    padding: 0rpx 32rpx 0rpx 32rpx;
  }

  .dailyExpenditure_flex_1 {
    background: rgba(255, 255, 255, 1);
    background-size: 100% auto;
  }

  .dailyExpenditure_fd1_1_c0_c0 {
    color: #2568AE;
    font-size: 28rpx;
    font-weight: 400;
    line-height: 32rpx;
  }

  .dailyExpenditure_fd1_1_c0 {
    background: rgba(37, 104, 174, 0.1);
    margin: 22rpx 0rpx 0rpx 30rpx;
    padding: 8rpx 26rpx 8rpx 26rpx;
    border-radius: 28rpx;
    background-size: 100% auto;
  }

  .dailyExpenditure_fd1_1 {
    padding: 0rpx 0rpx 20rpx 0rpx;
  }

  .dailyExpenditure_linefd1_0_c0 {
    background: rgba(37, 104, 174, 1);
    width: 40rpx;
    height: 6rpx;
    top: 80rpx;
    background-size: 100% auto !important;
    border-radius: 3rpx;
  }

  .checkTitlefd1_0_c0 {
    font-weight: 500 !important;
    font-size: 32rpx !important;
    color: #2568AE !important;
    background-color: rgba(255, 255, 255, 1) !important;
  }

  ::v-deep .dailyExpenditure_benbenTabsfd1_0_c0 {
    background: #fff;
    width: 750rpx;
    height: 90rpx;
    white-space: nowrap;
    text-align: center;
    font-size: 32rpx;
    font-weight: 400;
    color: #666666;
  }

  .dailyExpenditure_flex_2 {
    padding: 24rpx 30rpx 0rpx 30rpx;
  }

  .dailyExpenditure_fd2_0_c4_c0 {
    background: rgba(37, 104, 174, 1);
    border-radius: 10rpx;
    width: 160rpx;
    line-height: 64rpx;
    font-size: 30rpx;
    color: #fff;
  }

  .dailyExpenditure_fd2_0_c4 {
    margin: 32rpx 0rpx 0rpx 0rpx;
  }

  .dailyExpenditure_fd2_0_c3_c1_c0_c0 {
    width: 220rpx;
    height: 220rpx;
    border-radius: 0rpx 0rpx 0rpx 0rpx;
  }

  .dailyExpenditure_fd2_0_c3_c1_c0 {
    margin: 0rpx 30rpx 10rpx 0rpx;
  }

  .dailyExpenditure_fd2_0_c3_c0 {
    color: #999999;
    font-size: 28rpx;
    font-weight: 400;
    line-height: 32rpx;
    margin: 0rpx 43rpx 0rpx 0rpx;
  }

  .dailyExpenditure_fd2_0_c2_c0 {
    color: #999999;
    font-size: 28rpx;
    font-weight: 400;
    line-height: 32rpx;
    margin: 0rpx 44rpx 0rpx 0rpx;
  }

  .dailyExpenditure_fd2_0_c1_c1_c0_c0 {
    color: #999999;
    font-size: 28rpx;
    font-weight: 400;
    line-height: 32rpx;
    margin: 0rpx 40rpx 0rpx 0rpx;
    width: 100rpx;
  }

  .dailyExpenditure_fd2_0_c1_c0_c0_c1 {
    color: #101010;
    font-size: 28rpx;
    font-weight: 400;
    line-height: 32rpx;
  }

  .dailyExpenditure_fd2_0_c1_c0_c0_c0 {
    color: #999999;
    font-size: 28rpx;
    font-weight: 400;
    line-height: 32rpx;
    margin: 0rpx 40rpx 0rpx 0rpx;
  }

  .dailyExpenditure_fd2_0_c1_c0_c0 {
    margin: 24rpx 0rpx 0rpx 0rpx;
  }

  .dailyExpenditure_fd2_0_c1_c0 {
    width: 320rpx;
  }

  .dailyExpenditure_fd2_0_c0_c1_c1 {
    color: #2568AE;
    font-size: 32rpx;
    font-weight: 400;
    line-height: 32rpx;
  }

  .dailyExpenditure_fd2_0_c0_c1_c0 {
    color: rgba(102, 102, 102, 1);
    font-size: 32rpx;
    font-weight: 400;
    line-height: 32rpx;
  }

  .dailyExpenditure_fd2_0_c0_c0 {
    color: #101010;
    font-size: 34rpx;
    font-weight: 500;
    line-height: 36rpx;
  }

  .dailyExpenditure_fd2_0 {
    background: rgba(255, 255, 255, 1);
    border-radius: 16rpx;
    background-size: 100% auto;
    margin: 0rpx 0rpx 24rpx 0rpx;
    padding: 32rpx 24rpx 32rpx 24rpx;
  }
</style>
